yslifefandomcom-20200214-history
VIEWER PARAMETERS
Using Viewer parameters There are many ways of passing command line parameters to the Viewer. Command line On all platforms, when running the Viewer from a command shell you may specify parameters directly on the command line. For example: YSlifeOS.exe --channel "Test 123" --settings settings_workspace.xml --set InstallLanguage en Settings Files On all platforms, you can also construct a settings file and specify that with the --sessionsettings command line switch. Please see the table below to understand the settings variables engaged by each command-line switch. If you edit the user_settings/settings.xml file, that affects future YSlife sessions initiated from your OS account. Alternatively, you can edit the first_last/settings.xml file, which affects only YSLife sessions for that login user. For example, if your YSlife name is "Gaia Rossini", you should find that file in foobar_rossini/settings.xml. (Caution: this file uses a different XML format than the other settings files.) Visual Studio In Visual Studio, the command line paramaters are in the Debug Options pane of the newview project preferences. Ensure newview is your startup project, and launch the compiled viewer from within the debugger for these options to take effect. XCode In XCode, first select "newview" under the "Executables" group in XCode. Then open the "Get Info" dialog and click the "Arguments" tab. Add any of the following options to the "Arguments to be passed on launch" pane. Parameter reference NOTE: A parameter refers to a directive provided on the command-line following a double-dash (--). An argument is a value provided for a parameter. For example in --port 13001, "port" is the parameter and "13001" is the argument. Specifying new command line parameters To add a new command line parameter, use the configuration file app_settings/cmd_line.xml to map a command line paramter to a user setting. A parameter can have the following options: * desc - A description of the paramter. * short - a single character to map to the paramter. * count - the number of tokens to follow a option. * compose - true if the option can be specified multiple times. * positional - true if the option can be specified without --name. * last_option - true if the option should be the last option. * map-to - specify a user setting to map the option to. The file uses LLSD syntax. Use the existing options as reference. Examples Setting a Custom Cache Location To set a custom cache location when launching YSLife, you should use the set parameter with a value of NewCacheLocation followed by the desired cache folder to use. This will tell Second Life to startup using this location as a new cache location. NOTE: This may clear any existing cache folder that it has been using, to prevent this you can also the CacheLocation setting to the same value, which will preserve any cache folder saved in your viewer settings. This allows you to, use two different shortcuts in order to launch two different YSLife accounts, each with their own separate cache folder, allowing each to have a fully cached home location, for example. Or, a more complex case, a shortcut could create a temporary RAM disk for use as a cache folder, and set this value for YSLife to use, taking advantage of a RAM disk's speed, before saving the contents to disk afterwards. Category:Viewer Parameters Category:Viewer Category:CmdLine Category:Cache